#include"bits/stdc++.h"
using namespace std;
int len;
char n[20];
bool the_beginning_and_the_end_is_equal(char number[])
{
	if(number[0]==number[len])
	{
		return true;
	}
	else
	{
		return false;
	}
}
int main()
{
	cin>>n;
	len=strlen(n)-1;
	if(the_beginning_and_the_end_is_equal(n))
	{
		cout<<"YES";
	}
	else
	{
		cout<<"NO";
	}
}
